<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<link rel="stylesheet" type="text/css" href="../css/identify.css" />
<link rel="stylesheet" type="text/css" href="../css/layout.css" />
<!--  <link rel="stylesheet" type="text/css" href="../css/account.css" />-->
<link rel="stylesheet" type="text/css" href="../css/style.css" />
<link rel="stylesheet" type="text/css" href="../css/control_index.css" />

<!-- 
<link rel="stylesheet" type="text/css" href="../css/bootstrap-responsive.min.css" />
<link rel="stylesheet" type="text/css" href="../css/bootstrap-theme.min.css" />
<link rel="stylesheet" type="text/css" href="../css/bootstrap.min.css" /> -->

<script type="text/javascript" src="../js/jquery.js"></script>
<script type="text/javascript" src="../js/layer.js"></script>
<script type="text/javascript" src="../js/haidao.offcial.general.js"></script>
<script type="text/javascript" src="../js/select.js"></script>
<script type="text/javascript" src="../js/haidao.validate.js"></script>
<title>Insert title here</title>
</head>
<body style="font-size: 16px;">
	<div class="view-topbar">
			<div class="topbar-console">
				<div class="tobar-head fl">
					<a href="#" class="topbar-logo fl">
					<span><img src="Images/logo.png" width="20" height="20"/></span>
					</a>
					<a href="javascript:void(0);" class="topbar-home-link topbar-btn text-center fl"><span>管理控制台</span></a>
				</div>
			</div>
			<div class="topbar-info">
				<ul class="fr">
					<li class="fl dropdown topbar-notice topbar-btn">
					<a href="#" class="dropdown-toggle">
					<span class="icon-notice"></span>
					<!-- 要不要进行信息提示 -->
					<!--  <span class="topbar-num have"></span>-->
					<!--have表示有消息，没有消息去掉have-->
					</a>
					</li>
					<li class="fl topbar-info-item">
					<div class="dropdown">
						<a href="#" class="topbar-btn">
						<span class="fl text-normal">帮助与文档</span>
						<span class="icon-arrow-down"></span>
						</a>
						<ul class="dropdown-menu">
							<li><a href="#">使用手册</a></li>
						</ul>
					</div>
					</li>
					<li class="fl topbar-info-item">
					<div class="dropdown">
						<a href="#" class="topbar-btn">
						<span class="fl text-normal">${manager.uname}</span>
						<span class="icon-arrow-down"></span>
						</a>
						<ul class="dropdown-menu">
						<!-- 退出 -->
							<li><a href="exit">退出</a></li>
						</ul>
					</div>
					</li>
				</ul>
			</div>
		</div>
		<div class="view-body">
			<div class="view-sidebar">
				<div class="sidebar-content">
					<div class="sidebar-nav" style="width: 200px;">
						<div class="sidebar-title">
							<a href="#">
								<span class="icon"><b class="fl icon-arrow-down"></b></span>
								<span class="text-normal">商家信息管理</span>
							</a>
						</div>
						<ul class="sidebar-trans">
							<li>
							<!-- 全部商家页面 -->
								<a href="getMerchantList?action=all">
									<b class="sidebar-icon"></b>
									<span class="text-normal">全部商家列表</span>
								</a>
							</li>
							<li>
							<!-- 待审核商家页面 -->
								<a href="getMerchantList?action=search&status=0">
									<b class="sidebar-icon"></b>
									<span class="text-normal">待审核商家列表</span>
								</a>
								<a href="getMerchantList?action=search&status=1">
									<b class="sidebar-icon"></b>
									<span class="text-normal">已审核商家列表</span>
								</a>
								<a href="getMerchantList?action=search&status=2">
									<b class="sidebar-icon"></b>
									<span class="text-normal">已拉黑商家列表</span>
								</a>
								<a href="getMerchantList?action=search&status=3">
									<b class="sidebar-icon"></b>
									<span class="text-normal">已驳回商家列表</span>
								</a>
							</li>
						</ul>
					</div>
					<!-- 下面div进行保留部分 -->
					<!--  
					<div class="sidebar-nav">
						<div class="sidebar-title">
							<a href="#">
								<span class="icon"><b class="fl icon-arrow-down"></b></span>
								<span class="text-normal">***</span>
							</a>
						</div>
						<ul class="sidebar-trans">
							<li>
								<a href="userInfo.html">
									<b class="sidebar-icon"><img src="Images/icon_cost.png" width="16" height="16" /></b>
									<span class="text-normal">账号管理</span>
								</a>
							</li>
						</ul>
					</div>-->
				</div>
			</div>
			<div style="background-color: white;width: 100%;height: 100%;">
				<table class="table table-striped table-hover" style="margin-left: 10px;">
		<tr><td colspan="3" align="center" style="text-align: center">全部商家列表</td></tr>
		<tr>
			<td width="45" align="center">商家名字</td>
			<td width="45" align="center">商家地址</td>
			<td width="45" align="center">状态</td>
		</tr>
		<c:forEach var="merchant" items="${merchantAllList}" varStatus="status">
			<c:if test="${status.count%2==0}" >
              <tr>
           </c:if>
           <c:if test="${status.count%2!=0}" >
              <tr style="background-color: #d9edf7">
           </c:if>
			<td align="center">	
				<a href="getMerchantDetails?id=${merchant.id }&status=${merchant.status}" target="_blank" top=100,left=100,width=300,height=200">${merchant.uname }</a>
			</td>
			<td align="center">${merchant.address }</td>
			<td align="center">
			<c:if test="${merchant.status==0 }">
				未审核
			</c:if>
			<c:if test="${merchant.status==1 }">
				已审核
			</c:if>
			<c:if test="${merchant.status==2 }">
				已拉黑
			</c:if>
			<c:if test="${merchant.status==3 }">
				驳回
			</c:if>
			</td>
		</tr>
		</c:forEach>
	</table>
			
			
			</div>
			<!-- <div style="height: 100%;float: right;width: 91%;" >
				<iframe id="iframe" style="background-color: white;" width="100%"
					height="100%"  frameborder="0" seamless src=""></iframe>
			</div> -->
		</div>

		<script>
			$(".sidebar-title").on('click', function() {
				if ($(this).parent(".sidebar-nav").hasClass("sidebar-nav-fold")) {
					$(this).next().slideDown(200);
					$(this).parent(".sidebar-nav").removeClass("sidebar-nav-fold");
				} else {
					$(this).next().slideUp(200);
					$(this).parent(".sidebar-nav").addClass("sidebar-nav-fold");
				}
			});
		</script>
</body>
</html>